Class FCMRegistrar
- java.lang.Object
-
- com.amazon.A3L.messaging.FCM.registration.FCMRegistrar
-
public class FCMRegistrar extends java.lang.ObjectDevice registration class for Firebase Messaging
-
-
Constructor Summary
Constructors Constructor Description FCMRegistrar()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description com.google.android.gms.tasks.Task<java.lang.String>getToken()Invokes FCM's getToken, which creates the new deviceToken if one does not exist.voidregisterDevice(OnInitCallback onInitCallback)FCM Device registration method which starts registration by trying to access deviceToken, and waits for FCM to finish registration or throw exception
-
-
-
Method Detail
-
getToken
public com.google.android.gms.tasks.Task<java.lang.String> getToken()
Invokes FCM's getToken, which creates the new deviceToken if one does not exist.- Returns:
- Task with token
-
registerDevice
public void registerDevice(@NonNull OnInitCallback onInitCallback)FCM Device registration method which starts registration by trying to access deviceToken, and waits for FCM to finish registration or throw exception- Parameters:
onInitCallback- : optional callback provided by app to receive device registration status
-
-